import java.util.Scanner;

public class Fib {
	public static long calculate1(long i){
		if (i < 2) {return i;}
		return calculate1(i - 1) + calculate1(i - 2);
	}

	public static long calculate2(long n){
		int a = 1,b = 1,c = 1;
		if(n < 1) { return -1; }
		for(int i = 2;i < n; i++) {
			c=a+b;
			a=b; b=c; 
	    }
		return c;
	}

	public static Double calculate3(long n){
		double gh5=Math.sqrt((double)5);
		return (Math.pow((1+gh5),n)-Math.pow((1-gh5),n))/(Math.pow((double)2,n)*gh5);
	}

	public static void main(String[] args) {
		Scanner s = new Scanner(System.in);
		long n = Long.valueOf(s.next());
		System.out.println(calculate1(n));
		System.out.println(calculate2(n));
		System.out.println(calculate3(n));
		s.close();
	}
}
